import { Controller } from "@nestjs/common";
import { HttpCatsService } from "./http-cat.service";
import { Get } from "@nestjs/common";
import { Public } from "src/decorators/is-public.decorator";
import { Cat } from "src/common/types/cats.type";

@Controller('/http-cat')
export class HttpCatsController {
    constructor(private readonly httpCatsService: HttpCatsService) { }

    @Public()
    @Get('/find-all')
    async findAll(): Promise<Cat[]> {
        return await this.httpCatsService.findAll();
    }
}
